package ai.people.platform.archives.service;

import ai.people.netmon.framework.domain.archives.entity.WorkOrder;
import ai.people.netmon.framework.domain.archives.request.WorkOrderListRequest;
import ai.people.netmon.framework.domain.archives.request.WorkOrderReplayRequest;
import ai.people.netmon.framework.domain.archives.request.WorkOrderRequest;
import ai.people.netmon.framework.domain.archives.vo.WorkOrderDetailVO;
import ai.people.netmon.framework.domain.archives.vo.WorkOrderListVO;
import ai.people.netmon.framework.model.response.PageResponse;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author zhenglin
 * @since 2022-05-31
 */
public interface WorkOrderService extends IService<WorkOrder> {

    /**
     * 工单列表(用户)
     *
     * @param request 请求
     * @return {@link List}<{@link WorkOrderListVO}>
     */
    PageResponse<WorkOrderListVO> myWorkOrderList(WorkOrderListRequest request);

    /**
     * 工单列表(管理员)
     *
     * @param request 请求
     * @return {@link PageResponse}<{@link WorkOrderListVO}>
     */
    PageResponse<WorkOrderListVO> adminWorkOrderList(WorkOrderListRequest request);

    /**
     * 新增工单
     *
     * @param addVO 添加
     */
    void addWorkOrder(WorkOrderRequest addVO);

    /**
     * 工单详情
     *
     * @param id id
     * @return {@link WorkOrderDetailVO}
     */
    WorkOrderDetailVO getWorkOrderDetail(Long id);

    /**
     * 回复工单
     *
     * @param replayRequest 请求
     */
    void replay(WorkOrderReplayRequest replayRequest);


    /**
     * 终止工单
     *
     * @param id id
     */
    void stopWorkOrder(Long id);

    /**
     * 受理工单
     *
     * @param id id
     */
    void acceptWorkOrder(Long id);

    /**
     * 完成工单
     *
     * @param id id
     */
    void completeWorkOrder(Long id);


}
